{% extends "base.html" %}
{# Copyright The IETF Trust 2015, All Rights Reserved #}
{% load origin textfilters ietf_filters static %}
{% block pagehead %}
    <link rel="stylesheet" href="{% static "ietf/css/highcharts.css" %}">
{% endblock %}
{% block title %}Active areas{% endblock %}
{% block content %}
    {% origin %}
    <h1>Areas</h1>
    <p>
        The IETF divides its work into a number of areas, each comprised of working groups that relate to that area's focus. The area structure is defined by the IESG, and the IESG can add areas, redefine areas, merge areas, change the number of ADs assigned to an area, or close down areas.
    </p>
    <p>
        Changes to the area structure affect the IETF in many ways; decisions to change the area structure are taken in consultation with the community.
    </p>
    <p>
        When changing the area structure, the IESG can decide which members are responsible for new and changed areas, including making one sitting AD responsible for multiple areas, but the IESG can only add new members through the
        <a href="https://www.ietf.org/nomcom/index.html">NomCom process</a>.
    </p>
    <p>
        The primary task of area management is handled by one or two Area Directors per area. An AD may be advised by one or more directorates, which are created, selected, chaired and if necessary disbanded by the AD. Directorates may be specific to an area, specific to a technology, or chartered in some other fashion.
    </p>
    <p>
        The ADs for an area are jointly responsible for making sure the WGs in the area are well coordinated, that there is coverage for the technologies needed in the area, and that the challenges most important to the Internet in that area are indeed being worked on.
    </p>
    <p>
        For more information about the role of the IESG in areas and working groups, please see
        <a href="https://www.ietf.org/rfc/rfc3710.txt">RFC 3710 ("An IESG charter")</a>,
        Section 6 and
        <a href="https://www.ietf.org/rfc/rfc2418.txt">RFC 2418 ("IETF Working Group Guidelines and Procedures")</a>.
    </p>
    <p>
        A full list of active working groups, sorted by area, may be found at
        <a href="{% url 'ietf.group.views.active_groups' group_type='wg' %}">
            {% url 'ietf.group.views.active_groups' group_type='wg' %}
        </a>.
    </p>
    <p>
        The IESG decides which areas working groups belong to. The charter of each area is listed below:
    </p>
    <ul>
        {% for area in areas %}
            <li>
                <a href="#id-{{ area.acronym|slugify }}">{{ area.acronym|upper }} – {{ area.name }}</a>
            </li>
        {% endfor %}
    </ul>
    <p>
        The following diagrams show the sizes of the different areas and working groups,
        based on the number of documents - and pages - a group has worked on in the last three years.
    </p>
    <div class="row mt-3">
        <div class="col-sm chart text-center" data-area="ietf" data-dataset="docs">
            <div class="spinner-border" role="status">
              <span class="visually-hidden">Loading...</span>
            </div>
        </div>
        <div class="col-sm chart text-center" data-area="ietf" data-dataset="pages">
            <div class="spinner-border" role="status">
              <span class="visually-hidden">Loading...</span>
            </div>
        </div>
    </div>
    {% for area in areas %}
        <h2 class="mt-5" id="id-{{ area.acronym|slugify }}">
            {{ area.name }}
            <a href="{% url 'ietf.group.views.active_groups' group_type='wg' %}#{{ area.acronym|upper }}">({{ area.acronym|upper }})</a>
        </h2>
        {% if area.description %}
            <p>
                {{ area.description|urlize_ietf_docs|linkify|safe }}
            </p>
        {% endif %}
        {% include "group/group_stats_modal.html" with group=area only %}
    {% endfor %}
{% endblock %}
{% block js %}
    <script src="{% static 'ietf/js/highcharts.js' %}"></script>
    <script>
        $(function () {
            group_stats("{% url 'ietf.group.views.group_stats_data' %}", ".chart");
        });
    </script>
{% endblock %}